package com.cn.demo.mapper;

import com.cn.demo.entity.Teacher;
import com.cn.demo.entity.TeacherExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;

@Component
public interface TeacherMapper {
    long countByExample(TeacherExample example);

    int deleteByExample(TeacherExample example);

    int deleteByPrimaryKey(String teacherId);

    int insert(Teacher record);

    int insertSelective(Teacher record);

    List<Teacher> selectByExample(TeacherExample example);

    Teacher selectByPrimaryKey(String teacherId);

    int updateByExampleSelective(@Param("record") Teacher record, @Param("example") TeacherExample example);

    int updateByExample(@Param("record") Teacher record, @Param("example") TeacherExample example);

    int updateByPrimaryKeySelective(Teacher record);

    int updateByPrimaryKey(Teacher record);

    int add(Teacher teacher);

    List<Teacher> get(Teacher teacher);

    int delete(String[] teacherIdList);

    Teacher getByTeacherId(@Param("teacherId")String teacherId);

    int upDateByTeacherId(Teacher teacher);

    Teacher checkInfo(@Param("teacherId")String teacherId,@Param("oldPassword") String oldPassword);

    int updatePassword(@Param("teacherId")String teacherId, @Param("affirmPassword")String affirmPassword);

    Teacher login(Teacher teacher);

    int updateToken(@Param("token")String token, @Param("teacherId")String teacherId);
}